package com.hmdp.utils;

public interface ILock {
    /**
     * 获取锁
     * timeoutSec 锁持着有的超时时间，过期后自动释放
     * true代表获取锁成功，false代表获取锁失败
     * boolean tryLock(long timeoutSec);
     * <p>
     * /**
     * 释放锁
     */

    boolean tryLock(long timeoutSec);

    void unlock();
}
